#include "head.h"

int main() {
    int type;
    int cnt[6] = {0};
    while (1) {
        type = recv_from_queue(65537);
        if (type == -1) {
            break;
        }
        switch (type) {
            case 1:
                cnt[0]++;
                break;
            case 2:
                cnt[1]++;
                break;
            case 3:
                cnt[2]++;
                break;
            case 4:
                cnt[3]++;
                break;
            case 5:
                cnt[4]++;
                break;
            case 6:
                cnt[5]++;
                break;
        }
    }
    for (int i = 0; i < 6; i++) {
        printf("type(%d) : %d\n", i + 1, cnt[i]);
    }

    return 0;
}